<!-- 空白页面参考模版 -->
{extend name='public/base' /}
{block name='content'}
{include file='public/content_header' /}
<section class="content">
        <div class="container-fluid">
            <div class="row">
                <div class="col-12">
                    <div class="card">
                        <div class="card-header">
                            <button class="btn btn-default btn-sm ReloadButton" data-toggle="tooltip" title="刷新列表数据">
                                <i class="fas fa-redo"></i> 刷新
                            </button>
                        </div>
                        <div class="card-body table-responsive p-0" >
                            <table class="table table-hover table-bordered dataTable text-nowrap">
                                <thead>
                                <tr>
                                    <th>表名</th>
                                    <th>注释</th>
                                    <th>引擎</th>
                                    <th>排序规则</th>
                                    <th>记录数</th>
                                    <th>表大小</th>
                                    <th>创建时间</th>
                                    <th>更新时间</th>
                                    <th>操作</th>
                                </tr>
                                </thead>
                                <tbody>
                                {foreach name='data' id='item'}
                                <tr>
                                    <td>{$item.name}</td>
                                    <td>{$item.comment}</td>
                                    <td>{$item.engine}</td>
                                    <td>{$item.collation}</td>
                                    <td>{$item.rows}</td>
                                    <td>{$item.data_length|format_size}</td>
                                    <td>{$item.create_time}</td>
                                    <td>{$item.update_time}</td>

                                    <td class="td-do">

                                        <button data-data='{"name":"{$item.name}"}' data-url="view.html" data-confirm="2"
                                           data-type="2" class="AjaxButton btn btn-default btn-xs"
                                           data-title="{$item.name}({$item.comment})表详情" title="查看表详情"
                                           data-toggle="tooltip">
                                            <i class="fa  fa-info-circle"></i>
                                        </button>

                                        <button data-data='{"name":"{$item.name}"}' data-go="1" data-url="optimize.html"
                                           data-confirm="2" class="AjaxButton btn btn-warning btn-xs" title="优化表"
                                           data-toggle="tooltip">
                                            <i class="fas fa-sync"></i>
                                        </button>


                                        <button data-data='{"name":"{$item.name}"}' data-go="1" data-url="repair.html"
                                           data-confirm="2" class="AjaxButton btn btn-primary btn-xs" title="修复表"
                                           data-toggle="tooltip">
                                            <i class="fas fa-circle-notch"></i>
                                        </button>
                                    </td>
                                </tr>
                                {/foreach}
                                </tbody>
                            </table>
                        </div>
                    </div>
                </div>
            </div>
        </div>
</section>
{/block}